//派工管理

import http from '@/lib/http'





//10个
//4-01查询通知单列表  /dispatch/notice
export function getDispatchAll(params) {
    return http.getRequest(`/dispatch/notice`, params)
}

//4-02查看派工详情   /dispatch/detail
export function getDispatchDetail(params) {
    return http.getRequest(`/dispatch/detail`, params)
}

//4-03-a获取工艺版本数据  /dispatch/getpv
export function getDispatchPV(params) {
    return http.getRequest(`/dispatch/process/version`, params)
}

//4-03-b派工 /dispatch/create
export function createDispatch(params) {
    return http.postRequest(`/dispatch/create`, params)
}

//4-04二维码  /dispatch/qrcode
export function qrcodeDispatch(params) {
   return http.getRequest(`/dispatch/qrcode`, params)
}



//4-05修改   /dispatch/update
export function updateDispatch(params) {
    return http.postRequest(`/dispatch/update`, params)
}

//4-07终止派工单  /dispatch/stop
export function stopDispatch(params) {
    return http.getRequest(`/dispatch/stop`, params)
}

//4-08单双机审核  /dispatch/single
export function singleDispatch(params) {
    return http.getRequest(`/dispatch/single`, params)
}

//4-09完工确认   /dispatch/confirm
export function confirmDispatch(params) {
    return http.getRequest(`/dispatch/confirm`, params)
}


// 4-10 派工单查询
export function queryDispatchForm(params){
    return http.getRequest(`/dispatch/forms`, params)
}

// 4-11 派工单详情查询
export function getDispatchProductDetail(params){
    return http.getRequest(`/product`, params)
}

// 拆单
export function splitDispatchForm(params){
    return http.getRequest(`/form/split`, params)
}

// 调整工时
export function changeQuotaHourApi(params){
    return http.getRequest(`/work/hour/change`, params)
}

// 自制转外协
export function toOutsource(params){
    return http.getRequest(`/dispatch/outsource`, params)
}

// 报验回退
export function sendInspectionBackApi(params){
    return http.getRequest(`/inspection/revoke`, params)
}

// 自制转外协
export function sendBackProcess(params){
    return http.getRequest(`/inspection/back/all`, params)
}